/*
 * CS_GUILD_COOLDOWN.cpp
 *
 *  Created on: 2014. 8. 5.
 *      Author: spencer
 */



#include "../../User.h"
#include "../../Command.h"
#include "../../Proxy.h"

#include "../protocol/Guild.h"

namespace ProjectZ { namespace NCommand {

void Command::CS_GUILD_COOLDOWN(User * pUser, ::Network::Packet * pPacket)
{
/*
//-ACK_GUILD_CREATE_NOT_COOL_DOWN_YET를 받았을 경우 요청
CS_GUILD_REQ_COOL_DOWN				0x3270
{
}

SC_GUILD_REQ_COOL_DOWN				0x3271
{
	s16			s16ack;
	u64			u64CurrServerTime;		//현재 서버시간
	u64			u64LeaveTime;			//탈퇴시간
}
*/
	PREPARE_PACKET;


	GuildCoolDownSyn syn;
	syn.user_seq	= pUser->GetUserSeq();
	syn.guild_seq = pUser->GetGuildSeq();


//	DEBUGLOG("%s> user_seq: %d"
//			, __FUNCTION__
//			, syn.user_seq
//			);

	if (false == NProxy::SendGuildServer(pUser, syn))
	{
		::Network::Packet * pAck = ::Network::GETPACKETPOOL()->SEND_NEW();
		*pAck << static_cast<int16_t>(ACK_UNKNOWN_ERROR);
		pAck->MakePacket(CMD_SC_GUILD_COOLDOWN);
		pUser->Send(pAck);
		return;
	}
}

} /*NCommand*/ } /*ProjectZ*/
